/*
 * Copyright (c) 2006-2021, RT-Thread Development Team
 *
 * SPDX-License-Identifier: Apache-2.0
 *
 * Change Logs:
 * Date           Author       Notes
 * 2021-05-24     18782       the first version
 */
#ifndef APPLICATIONS_SOCKET_API_SOCKET_API_H_
#define APPLICATIONS_SOCKET_API_SOCKET_API_H_

typedef struct rt_tcpclient rt_tcpclient_t;
typedef void (*rx_cb_t)(void *buff, rt_size_t len);

rt_tcpclient_t *rt_tcpclient_start(uint8_t tcpclient_number,const char *hostname, rt_uint32_t port);

rt_int32_t tcpclient_recv_data(int sock_fd, char *recv_buff, rt_size_t len);
rt_int32_t tcpclient_send_data(int sock_fd, char *send_buff, rt_size_t len);
static void rt_tc_test_deinit(rt_tcpclient_t *thiz);
int rt_tc_test_init(uint8_t tcpclient_number,const char *hostname, rt_uint32_t port);

#endif /* APPLICATIONS_SOCKET_API_SOCKET_API_H_ */
